package principle.decorator;

/**
 * @author malguy-wang sir
 * @create ---
 */
public class Decorator extends drink{
    private drink d;
    public Decorator(drink drink){ d=drink; }
    @Override
    public float cost() { return super.getPrice()+d.cost(); }
    @Override
    public String getDes() { return super.getDes()+" "+super.getPrice()+" "+d.getDes(); }
}
